home *** CD-ROM | disk | FTP | other *** search
/ Amiga Developer CD 2.1 / Amiga Developer CD v2.1.iso / Reference / DevCon / Milan_1991 / Devcon91.1 / Libraries / Intuition / other_examples / StrDemo / strgad.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-09-01  |  1.1 KB  |  37 lines

  1. /* strgad.h -- easy to build string gadgets :ts=8    */
  2.  
  3. /*
  4. Copyright (c) 1989 Commodore-Amiga, Inc.
  5.  
  6. Executables based on this information may be used in software
  7. for Commodore Amiga computers. All other rights reserved.
  8. This information is provided "as is"; no warranties are made.
  9. All use is at your own risk, and no liability or responsibility
  10. is assumed.
  11. */
  12.  
  13. struct SGSpec    {
  14.     struct RastPort    *sgs_RPort;    /* screen rastport        */
  15.     WORD    sgs_TxHeight;        /* height of gadget font    */
  16.     WORD    sgs_Left;
  17.     WORD    sgs_Top;
  18.     WORD    sgs_Width;        /* used for borders        */
  19.     char    *sgs_Title;        /* placed on left (NOT COPIED!)    */
  20.     char    *sgs_InitString;    /* initial contents of buffer    */
  21.     WORD    sgs_NumChars;        /* i'll add NULL terminator    */
  22.     WORD    sgs_StringActives;    /* str. gadg. specific Activation*/
  23.     WORD    sgs_ID;            /* gadget ID            */
  24. };
  25.  
  26. struct Gadget *getStringGadgets();
  27. struct Gadget *freeStringGadgets();
  28.  
  29. #define TITLEGAP    (12)    /* space between title and gadget    */
  30. #define BORDERGAP    (2)
  31. #define SGHEIGHT( rp )    (((rp)->TxHeight) + 4 + 2 * BORDERGAP)
  32.  
  33. /* internal communication    */
  34. #define MYCODETAB    1
  35. #define MYCODEBACKTAB    2
  36.  
  37.